package com.gccloud.design.common;

import com.gccloud.starter.plugins.validator.group.Insert;
import com.gccloud.starter.plugins.validator.group.Update;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.io.Serializable;

/**
 * 实现功能【角色实体公共类】
 *
 * @author hu.hongdou
 * @date 2022/2/21
 */
@Data
public class SysRoleGroupCommon implements Serializable {

    private static final long serialVersionUID = -7901588472474750609L;

    @ApiModelProperty(notes = "角色id")
    @NotBlank(message = "角色id不能为空", groups = {Update.class})
    private String id;

    @ApiModelProperty(notes = "角色名称")
    @NotBlank(message = "角色名称不能为空", groups = {Insert.class, Update.class})
    private String name;

    @ApiModelProperty(notes = "角色编码")
    @NotBlank(message = "角色编码不能为空", groups = {Insert.class, Update.class})
    private String code;

    @ApiModelProperty(notes = "机构id")
    @NotBlank(message = "机构id不能为空", groups = {Insert.class, Update.class})
    private String orgId;

    @ApiModelProperty(notes = "值班电话")
    @NotBlank(message = "值班电话不能为空", groups = {Insert.class, Update.class})
    private String dutyTelNo;

    @ApiModelProperty(notes = "值班移动电话")
    @NotBlank(message = "值班移动电话不能为空", groups = {Insert.class, Update.class})
    private String dutyMobileNo;

    @ApiModelProperty(notes = "是否接收值班短信")
    @NotNull(message = "是否接收值班短信不能为空", groups = {Insert.class, Update.class})
    private Boolean isAcceptMsg;

    @ApiModelProperty(notes = "值班邮箱")
    @NotBlank(message = "值班邮箱不能为空", groups = {Insert.class, Update.class})
    private String dutyEmail;

    @ApiModelProperty(notes = "是否接收值班EMAIL")
    @NotNull(message = "是否接收值班EMAIL不能为空", groups = {Insert.class, Update.class})
    private Boolean isAcceptEmail;

    @ApiModelProperty(notes = "值班PHS")
    @NotBlank(message = "值班PHS不能为空", groups = {Insert.class, Update.class})
    private String dutyPhsNo;

    @ApiModelProperty(notes = "角色类型")
    @NotBlank(message = "角色类型不能为空", groups = {Insert.class, Update.class})
    private String type;

    @ApiModelProperty(notes = "备注")
    private String remark;
}
